﻿$(function () {
    $(".show-big-img").on("click", function () {
        var src = $(this).attr("src");
        layer.open({
            type: 1,
            title: false,
            closeBtn: 1,
            area: '90%',
            skin: 'layui-layer-nobg', //没有背景色
            shadeClose: true,
            content: "<img src=" + src + " style=\"width:90%;\">"
        });
    });

    $(window).on("scroll", function () {
        var height = $(window).scrollTop();
        if (height > 50) {
            $("#go-top").removeClass("hidden");
        }
        else {
            $("#go-top").addClass("hidden");
        }
    });
    $("#go-top").on("click", function () {
        $('html, body').animate({ scrollTop: 0 }, 'fast');
    });


});

var DropdowmList = function (target) {
    var dropdownList = $(target).find(".dropdown-list");
    var status = $(dropdownList).data("status");
    if (status == "hide") {
        $(dropdownList).removeClass("hidden").data("status", "show");
    }
    else {
        $(dropdownList).addClass("hidden").data("status", "hide");
    }
};